FROM jhipster/jhipster

ADD .  /app
WORKDIR /app

RUN ./gradlew -Pprod bootRepackage

RUN ls -l

# add directly the war
ADD /build/libs/*.war /app.war

RUN sh -c 'touch /app.war'
VOLUME /tmp
CMD ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.war"]

EXPOSE 8080